#ifndef __ADC_H__
#define __ADC_H__

#include <Arduino.h>
#include "stm32g4xx_hal.h"

#ifdef __cplusplus
extern "C" {
#endif

extern ADC_HandleTypeDef hadc1;
extern volatile uint32_t iu_raw, iv_raw, iw_raw;
extern volatile uint16_t vdc_raw, speedref_raw;  // ADC values

void ADC1_Init(void);
void ADC1_ReadValues(void);  // Updated to read both regular channels

#ifdef __cplusplus
}
#endif

#endif // __ADC_H__
